<template>
	<view>
		<view class="head">
			<view class="zi">
				FKM
			</view>
			<view class="deng">
				<view class="top">
					<view class="shou">
						手机号
					</view>
					<input type="text" style="font-size: 30rpx;color: #212121;" v-model="form.username" placeholder="请输入手机号"/>
				</view>
				<view class="tow">
					<input type="text" placeholder="请输入密码" v-model="form.pass" style="font-size: 30rpx;color: #212121;"/>
				</view>
				<view class="three" @click="submit">
					登录
				</view>
				<view class="four">
					<label>
						<checkbox value="cb" />
						
					</label>
					<view class="yuedu">
						我已阅读并同意<text>《FKM用户协议》,《FKM隐私政策》</text>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import {login} from '@/apis/index.js'
	export default {
		data() {
			return {
				form:{}
			}
		},
		methods: {
			async submit(){
				let res = await login(this.form)
				console.log(res);
				uni.setStorageSync('token',res.data.token)
				if(res.errCode == '10000'){
					uni.switchTab({
						url:'/pages/home/home'
					})
				}
			}
		}
	}
</script>

<style>
	@import url(./Sign_in.less);
	/deep/uni-checkbox .uni-checkbox-input{
		width: 25rpx !important;
		height: 25rpx !important;
		/* border: #a1a1a1 !important; */
		font-size: 10rpx;
	}
</style>
